package cn.explink.dop.service;

import java.util.List;
import java.util.Map;

import org.springframework.transaction.annotation.Transactional;

import cn.explink.dop.entity.vo.DeliveryManVO;
import cn.explink.eap.core.common.service.CommonService;

/**
 * 业务层
 *
 * @author firefly 2015-2-28 11:04
 *
 */
@Transactional
public interface DeliveryManService extends CommonService {

	public String add(final DeliveryManVO del);

	public void modify(final DeliveryManVO del);

	public List<DeliveryManVO> getListData(final DeliveryManVO del);

	public Map<String, Object> getListDataByPage(final DeliveryManVO del, final int pageNum, final int pageSize);

	public DeliveryManVO queryById(String deliveryManId);

	public int deleteData(final List<DeliveryManVO> delList);

	public List<Map<String, Object>> userList();

	public DeliveryManVO queryByUserId(String Id);

	/**
	 *
	 * @Title: checkUserRelevance
	 * @Description: 判断用户是否已经有关联
	 * @author 孟凡岭
	 * @param @param userId
	 * @param @return
	 * @return boolean 返回类型
	 * @throws
	 */
	public boolean checkUserRelevance(String userId);

	/**
	 *
	 * @Title: chekcDelCertificates
	 * @Description: 判断证件编号是否已经存在
	 * @author 孟凡岭
	 * @param @param delCertificates
	 * @param @return
	 * @return boolean 返回类型
	 * @throws
	 */
	public boolean chekcDelCertificates(String delCertificates);

	/**
	 *
	 * @Title: getHeadImg
	 * @Description: 获取人员头像
	 * @author 孟凡岭
	 * @param @param userId
	 * @param @return
	 * @return String 返回类型
	 * @throws
	 */
	public String getHeadImg(String Id);

	/**
	 * @param i
	 *
	 * @Title: updateStatus
	 * @Description: 更改人员状态
	 * @author 孟凡岭
	 * @param @param ids
	 * @return void 返回类型
	 * @throws
	 */
	public void updateStatus(List<String> ids, int status);

	/**
	 *
	 * @Title: getUsersAndSelf
	 * @Description: 根据用户ID来查询信息
	 * @author 孟凡岭
	 * @param @param userId
	 * @param @return
	 * @return Map<String,Object> 返回类型
	 * @throws
	 */
	public Map<String, Object> getUsersAndSelf(String userId);

	/**
	 *
	 * @Title: getOpenDeliveryMan
	 * @Description: 获取启用中的配送人员
	 * @author 孟凡岭
	 * @param @return
	 * @return List<Map<String,Object>> 返回类型
	 * @throws
	 */
	public List<Map<String, Object>> getOpenDeliveryMan();

	/**
	 *
	 * @Title: deleteByUserId
	 * @Description: 删除配送员，逻辑删除
	 * @author 孟凡岭
	 * @param @param id
	 * @return void 返回类型
	 * @throws
	 */
	public void deleteByUserId(String id);

	/**
	 *
	 * @Title: getOpenAndReceiveDeliveryMan
	 * @Description: 获取启用中并且可以接单的配送人员
	 * @author 孟凡岭
	 * @param @return
	 * @return List<Map<String,Object>> 返回类型
	 * @throws
	 */
	public List<Map<String, Object>> getOpenAndReceiveDeliveryMan();

	/**
	 *
	 * @Title: queryManListPageByCompanyId
	 * @Description: 通过公司号查询配送员信息
	 * @author 孟凡岭
	 * @param @param man
	 * @param @param companyId
	 * @param @param pageNum
	 * @param @param pageSize
	 * @param @return
	 * @return Map<String,Object> 返回类型
	 * @throws
	 */
	public Map<String, Object> queryManListPageByCompanyId(DeliveryManVO man, String companyId, int pageNum, int pageSize);
}
